-
-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: 重构 Noneflow #231
feat: 重构 Noneflow #231
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #231 +/- ##
==========================================
- Coverage 98.13% 91.16% -6.98%
==========================================
Files 17 34 +17
Lines 966 1494 +528
==========================================
+ Hits 948 1362 +414
- Misses 18 132 +114 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
暂时还没看测试(
docker/docker_plugin_test.py
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
其实可以直接叫 plugin_test.py
吧。
.github/workflows/main.yml
Outdated
@@ -32,10 +32,10 @@ jobs: | |||
with: | |||
token: ${{ secrets.CODECOV_TOKEN }} | |||
|
|||
docker: | |||
noneflow-docker: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这里的修改没有意义吧
.github/workflows/docker-test.yml
Outdated
uses: docker/build-push-action@v5 | ||
with: | ||
file: ./docker/Dockerfile | ||
context: . |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这里把 context 放到 ./docker 就可以了吧,file 参数可以直接删掉。
docker/Dockerfile
Outdated
|
||
WORKDIR /tmp | ||
|
||
COPY ./docker/docker_plugin_test.py /tmp/plugin_test.py |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
COPY ./docker/docker_plugin_test.py /tmp/plugin_test.py | |
COPY ./docker_plugin_test.py /tmp/plugin_test.py |
else: | ||
test_result = await DockerPluginTest( | ||
DOCKER_IMAGES, project_link, module_name, config | ||
).run("3.10") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这里同理,不应该写死。
"load": plugin_test_output, | ||
"metadata": metadata, | ||
}, | ||
test_env={test_env: True}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这里的 test_env 字典是什么意思来着?
ISSUE_FIELD_TEMPLATE = "### {}" | ||
ISSUE_FIELD_PATTERN = r"### {}\s+" | ||
|
||
SKIP_COMMENT = "/skip" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
怎么有两个 skip comment(
src/plugins/github/constants.py
Outdated
@@ -0,0 +1,19 @@ | |||
NONEFLOW_MARKER = "<!-- NONEFLOW -->" | |||
|
|||
BOT_MARKER = "[bot]" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个用不上了。
) | ||
from githubkit.typing import Missing | ||
|
||
IssuesEvent: TypeAlias = ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pydantic 如果不支持 type 的话,可以临时禁用这个规则。
src/providers/store_test/__main__.py
Outdated
|
||
# 通过环境变量传递插件配置 | ||
config = os.environ.get("PLUGIN_CONFIG") | ||
data = os.environ.get("PLUGIN_DATA") | ||
|
||
asyncio.run(test.run(key, config, data)) | ||
if key and (config or data): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个只要提供了 key,应该就是要单次运行吧。
架构:
商店:
交互: